/*
 * @Author: YuanSong 
 * @Date: 2022-01-18 20:25:45 
 * @Last Modified by: YuanSong
 * @Last Modified time: 2022-01-18 21:17:12
 */


import React from "react";
import NormalPage from "@components/NormalPage";
import { withRouter, RouteComponentProps } from "react-router-dom";
import screening_room from "@/assets/img/screening_room.jpg";
import store from "store";
import InputItem from "@/components/MangePage/inputItem";
type IProps = RouteComponentProps;
class ManagePage extends React.Component<IProps> {
  constructor(props: any) {
    super(props);
  }
  readonly state={
      movieTitle:"",
      movieURL:"",
      movieCover:"",

  }
  onItemValueChange(value:string,value_var:string){
    this.setState({
        [value_var]:value
    })
  }
  submitMovieInfoUpload(){

  }

  render() {
    return (
      <NormalPage showHeader={true} showRightNavigation={true}>
        
        <div className="ManagePage-Parent-Wrapper">
          <p className="ManagePage-Title">配置-放映室板块</p>
          <p className="ManagePage-Subtitle">电影信息上传数据库</p>
          <div className="InputItem-Parent-Div">
            <InputItem title="电影名称" v_var="movieTitle" value={this.state.movieTitle} onItemValueChange={this.onItemValueChange.bind(this)}/>
            <InputItem title="电影地址" v_var="movieURL" value={this.state.movieURL} onItemValueChange={this.onItemValueChange.bind(this)}/>
            <InputItem title="电影封面" v_var="movieCover" value={this.state.movieCover} onItemValueChange={this.onItemValueChange.bind(this)}/>
          </div>
          <div className="Button Manage-Submit-Button" onClick={this.submitMovieInfoUpload.bind(this)}>提交</div>
        </div>
      </NormalPage>
    );
  }
}
export default withRouter(ManagePage);
